package com.blue.base.demo.dto;

import com.alibaba.fastjson.JSON;
import com.blue.base.common.bean.page.PageParam;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotNull;

/**
 * 用户传输Bean
 *
 * @author liulei
 * @version 1.0
 */
@ApiModel("用户分页查询入参")
@Data
@Accessors(chain = true)
public class UserPageDto {
    /**
     * 查询参数：开始时间
     */
    @ApiModelProperty(value = "开始时间", required = false)
    private String startTime;
    /**
     * 查询参数：结束时间
     */
    @ApiModelProperty(value = "结束时间", required = false)
    private String endTime;
    /**
     * 名称
     */
    @ApiModelProperty(value = "用户名称", required = false)
    private String name;
    /**
     * 部门ID
     */
    @ApiModelProperty(value = "部门ID", required = false)
    private Long deptId;
    /**
     * 分页参数
     */
    @NotNull(message = "分页参数不能为空")
    @ApiModelProperty(value = "分页参数", required = true)
    private PageParam pageParam;

    @Override
    public String toString() {
        return JSON.toJSONString(this);
    }
}
